package com.gjy.redis.controller;

import com.gjy.redis.domain.AjaxResult;
import org.redisson.Redisson;
import org.redisson.api.RMap;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author 宫静雨
 * @version 1.0
 * @since 2023-07-17 09:42:37
 */
@RestController
@RequestMapping("/hash")
public class HashController {

    @Resource
    private Redisson redisson1;

    @PostMapping("/add")
    public AjaxResult add() {
        RMap<Object, Object> map = redisson1.getMap("M_1");
        return AjaxResult.builder().build();
    }
}
